//	ID : pallab81
// 	PROG : 10400_1
// 	LANG : C++
// 	2011-09-01-19.08.45 Thursday
//
// 	"I have not failed, I have just found 10000 ways that won't work.
//


#include <iostream>
#include <algorithm>
#include <vector>
#include <sstream>
#include <fstream>
#include <string>
#include <list>
#include <map>
#include <set>
#include <queue>
#include <stack>
#include <functional>
#include <bitset>

#include <ctime>
#include <cassert>
#include <cstdio>
#include <cmath>
#include <cstring>
#include <climits>
#include <cstring>
#include <cstdlib>

using namespace std;

#define VI vector< int >
#define CI( x ) scanf("%d",&x)
#define CL( x ) scanf("%lld",&x)
#define CD( x ) scanf("%lf",&x )
#define fo(i,st,ed) for(int i = st ; i < ed ; ++i )
#define foE(i,st,ed) for(int i = st ; i <= ed ; ++i )
#define foit(i, x) for (typeof((x).begin()) i = (x).begin(); i != (x).end(); i++)
#define bip system("pause")
#define Int long long
#define pb push_back
#define SZ(X) (int)(X).size()
#define LN(X) (int)(X).length()
#define mk make_pair
#define f first
#define s second
#define SET( ARRAY , VALUE ) memset( ARRAY , VALUE , sizeof(ARRAY) )

inline void wait( double seconds ) {
    double endtime = clock()+( seconds* CLOCKS_PER_SEC );
    while( clock() < endtime ) {
        ;
    }
}
template< class T >
T Abs(T a) {
    return a < (T)0 ? -a : a ;
}
int dp1[101][32005];
int dp2[101][32005];
int n;
int to_be;
int w[101];

inline void Read() {
    CI(n);
    fo(i,0,n) {
        CI(w[i]);
    }
    CI(to_be);
}
inline void update(int id, int var) {
    if( Abs(var) > 32000 ) {
        return ;
    }
    if( var < 0 ) {
        dp2[id][ Abs(var) ]=1;
    } else {
        dp1[id][ var ]=1;
    }
}

inline void back_track( int id , int sum ) {
    if(id-1<0)return ;
    int var1;
    // try jog kore korchilam naki ?
    var1 = sum-w[id];
    if( Abs(var1)<=32000 && var1>=0 && dp1[id-1][ var1 ] ) {
        back_track(id-1,var1);
        printf("+%d",w[id]);
        return ;
    }
    if( Abs(var1)<=32000 && var1<0 && dp2[id-1][ Abs(var1) ] ) {
        back_track(id-1,var1);
        printf("+%d",w[id]);
        return ;
    }

    //try biyog kore korchilam naki
    var1 = sum+w[id];
    if( Abs(var1)<=32000 && var1>=0 && dp1[id-1][ var1 ] ) {
        back_track(id-1,var1);
        printf("-%d",w[id]);
        return ;
    }
    if( Abs(var1)<=32000 && var1<0 && dp2[id-1][ Abs(var1) ] ) {
        back_track(id-1,var1);
        printf("-%d",w[id]);
        return ;
    }

    //try gun kore korchilam naki
    if( sum%w[id] ==0 ) {
        var1 = sum/w[id];
        if( Abs(var1)<=32000 && var1>=0 && dp1[id-1][ var1 ] ) {
            back_track(id-1,var1);
            printf("*%d",w[id]);
            return ;
        }
        if( Abs(var1)<=32000 && var1<0 && dp2[id-1][ Abs(var1) ] ) {
            back_track(id-1,var1);
            printf("*%d",w[id]);
            return ;
        }

    }

    //try vag kore korchilam naki
    var1 = sum*w[id];
    if( Abs(var1)<=32000 && var1>=0 && dp1[id-1][ var1 ] ) {
        back_track(id-1,var1);
        printf("/%d",w[id]);
        return ;
    }
    if( Abs(var1)<=32000 && var1<0 && dp2[id-1][ Abs(var1) ] ) {
        back_track(id-1,var1);
        printf("/%d",w[id]);
        return ;
    }


}
inline void Proc() {
    SET(dp1,0);
    SET(dp2,0);

    update(0,w[0]);
    fo(i,1,n) {
        //taking care of positive numbers
        for(int j=0; j<=32000; ++j) {
            if(dp1[i-1][j]) {
                int var1 = j+w[i]; //sum
                int var2 = j-w[i]; //sub
                int var3 = j*w[i]; //mul
                update(i,var1);
                update(i,var2);
                update(i,var3);
                if( j%w[i]==0 ) {
                    update(i,j/w[i]);
                }
            }
        }
        //taking care of negative numbers
        for(int j=0; j<=32000; ++j) {
            if(dp2[i-1][j]) {
                int var1 = -j+w[i]; //sum
                int var2 = -j-w[i]; //sub
                int var3 = -j*w[i]; //mul
                update(i,var1);
                update(i,var2);
                update(i,var3);
                if( -j%w[i]==0 ) {
                    update(i,-j/w[i]);
                }
            }
        }
    }
    if( to_be >=0 && dp1[n-1][to_be]) {
        printf("%d",w[0]);
        back_track(n-1,to_be);
        printf("=%d\n",to_be);
    }
    else if( to_be < 0 && dp2[n-1][ Abs(to_be) ] ) {
        printf("%d",w[0]);
        back_track(n-1,to_be);
        printf("=%d\n",to_be);
    }
    else{
        printf("NO EXPRESSION\n");
    }
}
int main() {
//#ifndef ONLINE_JUDGE
//    freopen("in.txt","rt",stdin);
//#endif

    int cases=1;
    for( CI(cases) ; cases ; --cases ) {
        Read();
        Proc();
    }

    return 0;
}
